package com.ruoyi.ae.api.domain;
import com.alibaba.fastjson.JSONArray;
import lombok.Data;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;


/**
 * 上传Erp商品至AE的整合实体类
 */
@Data
public class AeProductPost {
    //postType 1-商品新增 2-商品信息普通修改 3-商品资质信息上传 4-商品调价
    private Integer postType;
    //商品类型  0 - 2.0商品 1 - 非2.0商品
    private Integer productType;

    private String shipsFromCountry;

    private Long aeProductId;

    private Long collectProductId;

    private Long sellerId;

    private String msr_eu_id;

    //采集商品表拓展
    private String add_unit;
    private BigDecimal add_weight;
    private String currency_code;
    private String base_unit;
    private Long bulk_discount;
    private Long bulk_order;
    private Long delivery_time;
    private String package_type;
    private String is_pack_sell;
    private Long lot_num;
    //区域定价结果
    private String aeop_national_quote_configuration;

    private AeopNationalQuoteConfiguration ational_quote_configuration;


    //卖家商品表拓展
    private AeopAEMultimedia aeop_a_e_multimedia;
    private Long group_id;
    private Long promis_template_id;
    private Long freight_template_id;
    private Long ws_valid_num;
    private String reduce_strategy;
    private String ean_code;


    //采集商品表
    private Long category_id;
    //    private String webDetail;
    private List<ModeSizeChartList> mode_size_chart_list;

    //卖家商品表
    private String gross_weight;
    private String image_u_r_ls;
    private Integer package_height;
    private Integer package_length;
    private Integer package_width;
    private String product_price;
    private Long product_unit;
    private Long sizechart_id;
    private String mobile_detail;
    private List<DetailSourceList> detail_source_list;
    private List<ErpProductSubject> subject_list;
    private List<MarketImages> market_images;

    //规格List
    private List<AeopAeProductSKUs> aeop_ae_product_s_k_us;

    private List<AeopAeProductPropertys> aeop_ae_product_propertys;

    private String aeop_qualification_struct_list;


    @Data
    public static class AeopAeProductSKUs {
        //卖家商品规格表
        private Long ipm_sku_stock;
        private String sku_code;
        private String sku_stock;
        private String currency_code;
        private String sku_discount_price;
        private String sku_price;
        private String id;
        //采集商品规格表
        private String gross_weight;
        private Integer package_height;
        private Integer package_width;
        private Integer package_length;

        private List<SkuNationalDiscountPrice> sku_national_discount_price;
        private List<AeopSKUProperty> aeop_s_k_u_property;
    }

    //sku分国家的日常促销价
    @Data
    public static class SkuNationalDiscountPrice {
        private String discount_price;
        private String shipto_country;
    }

    //sku属性列表
    @Data
    public static class AeopSKUProperty {
        private String sku_image;
        private String property_value_definition_name;
        private String property_value_id;
        private String sku_property_id;
        private String[] image_u_r_ls;
    }

    //商家产品标题
    @Data
    public static class ErpProductSubject {
        private String locale;
        private String value;
    }
    //营销图列表
    @Data
    public static class MarketImages {
        private String url;
        private Integer image_type;
    }
    //多媒体
    @Data
    public static class AeopAEMultimedia {
        private List<AeopAEVideos> aeop_a_e_videos;
    }

    @Data
    public static class AeopAEVideos {
        private Long media_id;
        private String media_type;
        private String poster_url;
        private String hips;
    }

    //模特相关
    @Data
    public static class ModeSizeChartList {
        private String waist;
        private String bust;
        private String height;
        private String mode_size;
    }

    @Data
    public static class DetailSourceList {
        private String locale;
        private String mobile_detail;
        private String web_detail;
    }

    /**
     * 产品属性信息
     */
    @Data
    public static class AeopAeProductPropertys {
        private String attr_name;
        private String attr_name_id;
        private String attr_value;
        private String attr_value_id;
    }

    @Data
    public static class AeopNationalQuoteConfiguration {
        private String configuration_data;
        private String configuration_type;
    }


    @Data
    public static class AeopQualificationStruct {
        private String key;
        private String value;
    }


}
